import { service_home_getBanner } from '@/services/home'
import type { DefineStoreOptions } from 'pinia'
const homeOptions: Omit<DefineStoreOptions<string, IHomeState, IHomeGetter, IHomeAction>, 'id'> = {
  state() {
    return {
      bannerList: []
    }
  },
  getters: {},
  actions: {
    async pinia_home_getBanner(params: any) {
      const { data } = await service_home_getBanner<IBanner[]>(params)
      this.bannerList = data
    }
  }
}

export const useHomeStore = defineStore('home', homeOptions)

export default useHomeStore
